<#assign pojo=oneToManyPojo.getOne()>
<#assign many=oneToManyPojo.getMany()>
<#assign ones=oneToManyPojo.getOnes()>
<#assign fields=pojo.getFilterdPojoFields()>
<#assign declarationName = pojo.importType(pojo.getDeclarationName())>
<#assign declarationNameFirstLetterLower = pojo.importType(pojo.getDeclarationNameFirstLetterLower())>
<#assign realPackageAndClassPath = "${pojo.getRealPackageAndClassPath()}">
<#assign masterid = pojo.getDeclarationNameFirstLetterLower()+"Id">
import React from 'react'
import PropTypes from 'prop-types'
import BaseToolBar from '../../components/ling/BaseToolBar'

function ${declarationName}ToolBar({on${declarationName}AddItem, on${declarationName}EditItem, on${declarationName}DeleteItem}) {

  const toolBarPorps = {
    schema: [
      {
        label: 'Create',
        onClick: on${declarationName}AddItem,
      },
      {
        label: 'Update',
        onClick: on${declarationName}EditItem,
      }
      ,
      {
        label: 'Delete',
        onClick: on${declarationName}DeleteItem,
      }
    ]
  }
  return (
    <BaseToolBar{...toolBarPorps}/>
  )
}

${declarationName}ToolBar.propTypes = {
  on${declarationName}AddItem: PropTypes.func,
  on${declarationName}EditItem: PropTypes.func,
  on${declarationName}DeleteItem: PropTypes.func,
}

export default ${declarationName}ToolBar